package me.zhengjie.app.system.rest;


import com.alibaba.fastjson.JSONObject;
import com.sun.imageio.plugins.common.ImageUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import me.zhengjie.utils.RequestHolder;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletRequest;


/**
 * @author sxnss_zxx
 * @date 2020-12-08
 */
@Api(tags = "公共类")
@RestController
@RequestMapping("/app/api/common")
public class CommonUtilController {

//    @ApiOperation("图片转换")
//    @PostMapping(value = "/generateImage")
//    public String generateImage(@RequestBody String base64Str) {
//        JSONObject jsonObject=JSONObject.parseObject(base64Str);
//        String str_image=jsonObject.get("base64Str").toString();
//        HttpServletRequest request = RequestHolder.getHttpServletRequest();
//        // 图片格式转换返回保存路径
////        String saveImagePath = ImageUtil.generateImage(str_image, request);
////        return saveImagePath;
//    }

}

